import Singleton from "../../../scripts/Singleton";
import { KuGoConfig } from "./KugoConfig";
import { KugoChessDataModel } from "./model/KugoChessDataModel";
import { KugoUserDataModel } from "./model/KugoUserDataModel";


export class KugoModel extends Singleton<KugoModel> {
    private _base: KugoChessDataModel = null
    private _userMgr: KugoUserDataModel = null
    constructor(){
        super()
        this._base = new KugoChessDataModel(KuGoConfig.GridSize)
        this._userMgr = new KugoUserDataModel()
    }

    /**棋盘数据 */
    get ChessBase(){
        return this._base
    }

    get UserMgr(){
        return this._userMgr
    }
}

export let kuModel:KugoModel = KugoModel.getInstance()